
//------------------------------------------------------------------------------

using Apps.Models;
using System;
using System.ComponentModel.DataAnnotations;
namespace Apps.Models.CONTRACT
{

    public partial class CONTRACT_INFOModel : Virtual_CONTRACT_INFOModel
    {
        public string SIGN_DATE_Str {
            get
            {
                if (SIGN_DATE != null) return Convert.ToDateTime(SIGN_DATE).ToString("yyyy-MM-dd");
                else return "";
            }
        }

        public string VALID_BEGIN_Str {
            get
            {
                if (VALID_BEGIN != null) return Convert.ToDateTime(VALID_BEGIN).ToString("yyyy-MM-dd");
                else return "";
            }
        }
        
        public string VALID_END_Str
        {
            get
            {
                if (VALID_END != null) return Convert.ToDateTime(VALID_END).ToString("yyyy-MM-dd");
                else return "";
            }
        }

        public string PURCHASE_BEGIN_Str
        {
            get
            {
                if (PURCHASE_BEGIN != null) return Convert.ToDateTime(PURCHASE_BEGIN).ToString("yyyy-MM-dd");
                else return "";
            }
        }

        public string PURCHASE_END_Str {
            get
            {
                if (PURCHASE_END != null) return Convert.ToDateTime(PURCHASE_END).ToString("yyyy-MM-dd");
                else return "";
            }
        }
    }
    public class Virtual_CONTRACT_INFOModel
	{
		[Display(Name = "合同基本信息编号")]
		public virtual string CONTRACT_ID { get; set; }
		[Display(Name = "供应商编号")]
		public virtual string SUPPLIER_ID { get; set; }
		[Display(Name = "合同流水号")]
		public virtual string ECONTRACT_CODE { get; set; }
		[Display(Name = "合同类型（枚举ContractType）")]
		public virtual Nullable<short> ECONTRACT_TYPE { get; set; }
		[Display(Name = "合同名称")]
		public virtual string NAME { get; set; }
		[Display(Name = "合同版本")]
		public virtual string VERSION { get; set; }
		[Display(Name = "合同类别（枚举ContractCategory）")]
		public virtual Nullable<short> CATEGORY { get; set; }
		[Display(Name = "合同总金额")]
		public virtual Nullable<decimal> MONEY_TOTAL { get; set; }
		[Display(Name = "合同总量")]
		public virtual Nullable<decimal> GOODS_TOTAL { get; set; }
		[Display(Name = "签订地址")]
		public virtual string SIGN_ADDRESS { get; set; }
		[Display(Name = "签订时间(YYYY-MM-DD)")]
		public virtual Nullable<System.DateTime> SIGN_DATE { get; set; }
		[Display(Name = "运输方式（枚举TransportType）")]
		public virtual Nullable<short> TRANSPORT_TYPE { get; set; }
		[Display(Name = "有效日期起(YYYY-MM-DD)")]
		public virtual Nullable<System.DateTime> VALID_BEGIN { get; set; }
		[Display(Name = "有效日期止(YYYY-MM-DD)")]
		public virtual Nullable<System.DateTime> VALID_END { get; set; }
		[Display(Name = "采购日期起(YYYY-MM-DD)")]
		public virtual Nullable<System.DateTime> PURCHASE_BEGIN { get; set; }
		[Display(Name = "采购日期止(YYYY-MM-DD)")]
		public virtual Nullable<System.DateTime> PURCHASE_END { get; set; }
		[Display(Name = "交货方式（枚举DeliveryType）")]
		public virtual Nullable<short> DELIVERY_TYPE { get; set; }
		[Display(Name = "备注")]
		public virtual string MARK { get; set; }
		[Display(Name = "双方约定")]
		public virtual string AGREED { get; set; }
		[Display(Name = "违约责任")]
		public virtual string DUTY { get; set; }
		[Display(Name = "不可抗力")]
		public virtual string FORCEMAJOR { get; set; }
		[Display(Name = "争议解决")]
		public virtual string ARGUE { get; set; }
		[Display(Name = "外部合同号")]
		public virtual string EXTERNAL_CODE { get; set; }
		[Display(Name = "币别（枚举CurrencyType）")]
		public virtual Nullable<short> CURRENCY { get; set; }
		[Display(Name = "汇率")]
		public virtual Nullable<decimal> RATE { get; set; }
		[Display(Name = "是否含税，0否 1是")]
		public virtual Nullable<bool> TAX { get; set; }
		[Display(Name = "唯一性标识 0否 1是")]
		public virtual Nullable<short> ISUNIQUE { get; set; }
		[Display(Name = "合同类型(细分)（枚举ContractToType）")]
		public virtual Nullable<short> DETAIL_TYPE { get; set; }
		[Display(Name = "合同模板")]
		public virtual string MODUAL { get; set; }
		[Display(Name = "结算方式说明")]
		public virtual string SETTLE_MARK { get; set; }
		[Display(Name = "付款方式（枚举PaymentType）")]
		public virtual Nullable<short> PAYMENT_TYPE { get; set; }
		[Display(Name = "预付比例")]
		public virtual Nullable<decimal> ADVANCE_RATIO { get; set; }
		[Display(Name = "预结算比例")]
		public virtual Nullable<decimal> SETTLE_RATIO { get; set; }
		[Display(Name = "结算煤量计量方式（枚举ValuationMethod）")]
		public virtual Nullable<short> VALUATION_METHOD { get; set; }
		[Display(Name = "结算单位")]
		public virtual string SETTLE_UNIT { get; set; }
		[Display(Name = "审批状态（枚举ExaminationStatus）")]
		public virtual Nullable<short> AUDIT_STATUS { get; set; }
		[Display(Name = "编制人")]
		public virtual string COMPILE_USER { get; set; }
		[Display(Name = "编制时间(YYYY-MM-DD HH24:MI:SS)")]
		public virtual Nullable<System.DateTime> COMPILE_DATE { get; set; }
		[Display(Name = "相关合同版本")]
		public virtual string RELATION_VERSION { get; set; }
		[Display(Name = "结算方式（枚举SettlementType）")]
		public virtual Nullable<short> SETTLE_TYPE { get; set; }
		[Display(Name = "审批流程模板编号")]
		public virtual string TEMPLATE_ID { get; set; }
		[Display(Name = "审批状态（枚举ApprovalStatus）")]
		public virtual Nullable<byte> APPROVAL_STATUS { get; set; }
		[Display(Name = "采购计划编号（采购、临购计划）")]
		public virtual string PLAN_PURCHASE_ID { get; set; }
		}
}
